#ifndef VECTORES_H_ 
  #define VECTORES_H_

#include <vector>
#include "Platform.h"

using std::vector;

void restarVectores(float const a[3],float const b[3],float c[3]);
void sumarVectores(float const a[3],float const b[3],float c[3]);
void normalize(float a[3]);
void normalize2(float a[3], float b[3]);
float length(float const a[3]);
void multVectorScalar(float a[3],float ms);
void divVectorScalar(float a[3],float ms);
void multVectorScalar2(float a[3],float ms,float b[3]);
float multVectores(float a[],float b[]);
float* asVector(float o);
bool pointIntRec(const float c[3],const Platform* p);
bool pointIntTriangle(
    const float p[3],
    const float A[3],
    const float B[3],
    const float C[3]);

class Vector3d {
    private:
        vector<float> coor;

    public:
        Vector3d();
        Vector3d(float, float, float);

        /** Convierte un numero en un vector */
        Vector3d(float);

        /// Operaciones con vectores
        Vector3d operator+(const Vector3d &v) const;
        Vector3d operator-(const Vector3d &v) const;
        Vector3d operator/(const float) const;
        Vector3d operator*(const float) const;

        // Normalizacion
        Vector3d operator~() const;

        /** Normaliza el vector */
        Vector3d &normalize();

        /** Calcula el largo del vector */
        float length() const;
};

#endif
